package Task4;

public class Task4 {
	public static void main(String[] args) {

		int array[] = new int[10];
		array[0] = 9;
		array[1] = 7;
		array[2] = 3;
		array[3] = 9;
		array[4] = 3;
		array[5] = 3;
		array[6] = 9;
		array[7] = 7;
		array[8] = 3;
		array[9] = 7;
		Task4 t4= new Task4();
		System.out.println("Number of 3: "+t4.schet(array,3));
		System.out.println("Number of 7: "+t4.schet(array,7));
		System.out.println("Number of 9: "+t4.schet(array,9));
	}
	public int schet(int[] ar,int k) {
		int i=0;
		for(int j=0;j<ar.length;j++){
			if(ar[j]==k) {
				i++;
			}
		}
		return i;
	}
}